
<script>
function abc(){
    var name=document.getElementById('search_key');
    name.className="ipt12";
}
function cc(x){
    var name=document.getElementById("con_five_"+x);
    var list=document.getElementById("five"+x);
    name.style.display="none";
    list.className="";
}
function setTab(name,cursel,n){
    for(i=1;i<=n;i++){
        var menu=document.getElementById(name+i);
        var con=document.getElementById("con_"+name+"_"+i);
        menu.className=i==cursel?"hover":"";
        con.style.display=i==cursel?"block":"none";
    }
}
function checkit(form)
{
    document.getElementById("username_imgchk").style.display = "";
    document.getElementById("usernice_imgchk").style.display = "";
    document.getElementById("useremail_pwd").style.display = "";
    document.getElementById("useremail_tpwd").style.display = "";
    document.getElementById("useremail_imgchk").style.display = "";
    if(form.user_name.value==""){
        alert("请输入用户名！");
        form.user_name.focus();
        return(false);
    }else{
       document.getElementById("username_imgchk").src = "/images/reg_right.jpg";
    }
    if(form.user_nice.value==""){
        alert("请输入昵称！");
        form.user_nice.focus();
        return(false);
    }else
       document.getElementById("usernice_imgchk").src = "/images/reg_right.jpg";
    if(form.password.value==""){
        alert("请输入密码！");
        form.password.focus();
        return(false);
    }else if(form.password.value.length<6){
        alert("用户密码字符过短！");
        form.password.focus();
        return(false);
    }else  if(form.password.value.length>12){
        alert("用户密码字符过长！");
        form.password.focus();
        return(false);
    }else
       document.getElementById("useremail_pwd").src = "/images/reg_right.jpg";
    if(form.repassword.value==""){
        alert("请输入重复密码！");
        form.repassword.focus();
        return(false);
    }else if(form.password.value!=form.repassword.value){
        alert("密码与重复密码不同！");
        form.repassword.focus();
        return(false);
    }else
    document.getElementById("useremail_tpwd").src = "/images/reg_right.jpg";
    if(form.user_email.value==""){
        alert("请输入电子邮件！");
        form.user_email.focus();
        return(false);
    }else if(form.user_email.value!=""){
        if(form.user_email.value.match(/^[\w-]+(\.[\w-]+)*@[\w-]+(\.[\w-]+)+$/)==null){
            alert("请输入正确的E-mail地址！");
            form.user_email.focus();
            return(false);
        }
    }else
    document.getElementById("useremail_imgchk").src = "/images/reg_right.jpg";
    form.password.value=$.md5(form.password.value);

}

</script>
<style type="text/css">.h2{height:50px;text-align:center;font-size:16px;font-family:'黑体','宋体';font-weight:normal;line-height:50px;}</style>

  <div class="main">
    <?php @include_component("system","menuNavigator",array("type"=>6,"cssStr"=>"address_tit2")) ;?>
       <div class="reg">
         <h2 class="h2"><span>ieasy.tv</span> 用户注册</h2>
         <div class="reg_sm">
            <h3>注册须知：</h3>
            <p>　　1.在本站注册的会员，必须遵守《互联网电子公告服务管理规定》，不得在本站发飙诽谤他人，侵犯他人隐私，侵犯他人知识产权，传播病毒，政治议论，商业讯息等信息。</p>           <p>　　2.在所有本站发表的文章，本站都具有最终编辑权，并且保留用于印刷或向第三方发飙的权利，如果你的资料不齐全，我们有权力不作任何通知使用你在本站发表的作品。</p>
         </div>
         <form method="post" action="<?php echo url_for('user/resultpage') ?>" id="form" name="form"  onsubmit="if ( !this.aa.checked ) { alert ( '您还没有阅读并同意《用户注册服务协议》' ); return false; }; return checkit(this);">
         <div class="reg_box">

           <ul>
              <li><b>登录账号：</b><input type="text" class="ipt211" id="user_name"  name="user_name" ><span id="chak_user">*长度在6-12位之间<img id="username_imgchk" style="display:none" src="/images/reg_wrong.jpg" /></span></li>
              <li><b>昵&nbsp;&nbsp;&nbsp;&nbsp;称：</b><input type="text" class="ipt211" id="user_nice"  name="user_nice" ><span id="chak_nice">*长度在6-12位之间<img style="display:none" id="usernice_imgchk" src="/images/reg_wrong.jpg" /></span></li>
              <li><b>登录密码：</b><input type="password" class="ipt211" name="password" ><span id="chak_pwd">*密码长度在6-12位之间<img style="display:none" id="useremail_pwd" src="/images/reg_wrong.jpg" /></span></li>
              <li><b>确认密码：</b><input type="password" class="ipt211" name="repassword"><span id="chak_repwd">*请再次输入密码<img style="display:none" id="useremail_tpwd" src="/images/reg_wrong.jpg" /></span></li>
              <li><b>电子邮件：</b><input type="text" class="ipt211" id="user_email" name="user_email" ><span id="chak_email">*格式为xxx@xxx.com<img style="display:none" id="useremail_imgchk" src="/images/reg_wrong.jpg" /></span></li>
              <li><b>性&nbsp;&nbsp;&nbsp;&nbsp;别：</b><input type="radio" name="sex" checked="" value="male" >男&nbsp;&nbsp;&nbsp;&nbsp;<input type="radio" name="sex" value="female" >女</li>
              </ul><input type="lable" name="lable" value="0" style="DISPLAY: none" >
         </div>

        <div class="reg_bj"><b>请填写有效的电子邮箱的地址，若忘记密码需要用您填写的电子邮箱找回。</b><br>
          <input name="aa" type="checkbox" value="" />我已阅读并接受“<a href="#" target="_blank">服务条款</a>”。
        </div>
        <div class="submit"><input name="a1" class="sear01" type="submit" value="提&nbsp;交" />　　<input name="a2" class="sear01" type="reset" value="重&nbsp;置" />　　<input name="a2" class="sear01" onclick="window.location.href='<?php echo url_for("user/login"); ?>';" type="button" value="返回登录" /></div>
        </form>
       </div>
 </div>
